$host_name = Read-Host "Enter MySQL host name (The default is: localhost)"
if ($host_name -eq "") { $host_name="localhost" }
$user_name = Read-Host "Enter MySQL user name (The default is root)"
if ($user_name -eq "") { $user_name="root" }
$user_password=""
while ($user_password -eq "")
{
   $user_password = Read-Host -assecurestring "Enter MySQL user password"
   if ((New-Object System.Management.Automation.PSCredential('dummy',$user_password)).GetNetworkCredential().Password  -eq "") { $user_password = "" }
}
$user_password | ConvertFrom-SecureString | Set-Content password.txt
$x= [xml]"<MySQLConfig>
<host>$host_name</host>
<user>$user_name</user>
</MySQLConfig>"
$x.Save(".\MySQLConfig.xml")

